package com.wangsh.usersCenter.demo.service;

import java.util.Map;

import com.wangsh.usersCenter.common.pojo.ApiResponse;
import com.wangsh.usersCenter.common.util.PageInfoUtil;
import com.wangsh.usersCenter.demo.pojo.ADemoDynasty;
import com.wangsh.usersCenter.demo.pojo.ADemoKing;

/**
 * 示例模块的主要service
 * 		所有的Service凡是名字中包含DbService的会开启事务
 * @author Wangsh
 */
public interface IDemoDbService
{
	/*----- 朝代模块管理开始 -----*/
	/**
	 * 添加一条朝代
	 * 
	 * @param demoDynasty
	 * @return
	 */
	ApiResponse<Object> saveOneDemoDynastyService(ADemoDynasty demoDynasty);

	/**
	 * 更新一条朝代
	 * 
	 * @param demoDynasty
	 * @return
	 */
	ApiResponse<Object> updateOneDemoDynastyService(ADemoDynasty demoDynasty);

	/**
	 * 删除一条朝代
	 * 
	 * @param demoDynasty
	 * @return
	 */
	ApiResponse<Object> deleteOneDemoDynastyService(Map<String, Object> condMap);

	/**
	 * 查询多条朝代
	 * 
	 * @param pageInfo
	 * @param type
	 * @param condMap
	 * @return
	 */
	ApiResponse<ADemoDynasty> findCondListDemoDynastyService(PageInfoUtil pageInfoUtil , Map<String, Object> condMap);

	/**
	 * 查询一条朝代
	 * 
	 * @param type
	 * @param condMap
	 * @return
	 */
	ApiResponse<ADemoDynasty> findOneDemoDynastyService(Map<String, Object> condMap);
	/*----- 朝代模块管理结束 -----*/
	
	/*----- 皇上模块管理开始 -----*/
	/**
	 * 添加一条皇上
	 * 
	 * @param demoKing
	 * @return
	 */
	ApiResponse<Object> saveOneDemoKingService(ADemoKing demoKing);

	/**
	 * 更新一条皇上
	 * 
	 * @param demoKing
	 * @return
	 */
	ApiResponse<Object> updateOneDemoKingService(ADemoKing demoKing);

	/**
	 * 删除一条皇上
	 * 
	 * @param demoKing
	 * @return
	 */
	ApiResponse<Object> deleteOneDemoKingService(Map<String, Object> condMap);

	/**
	 * 查询多条皇上
	 * 
	 * @param pageInfo
	 * @param type
	 * @param condMap
	 * @return
	 */
	ApiResponse<ADemoKing> findCondListDemoKingService(PageInfoUtil pageInfoUtil , Map<String, Object> condMap);

	/**
	 * 查询一条皇上
	 * 
	 * @param type
	 * @param condMap
	 * @return
	 */
	ApiResponse<ADemoKing> findOneDemoKingService(Map<String, Object> condMap);
	/*----- 皇上模块管理结束 -----*/
}
